package com.atguigu.gulimall.product.vo;

import com.fasterxml.jackson.annotation.JsonProperty;
import lombok.Data;
import lombok.NoArgsConstructor;

import java.util.List;

/**
 * @author nicc
 * @version 1.0
 * @className SpuSaveInfoVo
 * @date 2022-09-29 15:40
 */

@NoArgsConstructor
@Data
public class SpuSaveInfoVo {
    /**
     * id
     */
    @JsonProperty("id")
    private Long id;
    /**
     * spuName
     */
    @JsonProperty("spuName")
    private String spuName;
    /**
     * description
     */
    @JsonProperty("description")
    private String description;
    /**
     * category3Id
     */
    @JsonProperty("category3Id")
    private Long category3Id;
    /**
     * spuImageList
     */
    @JsonProperty("spuImageList")
    private List<SpuImageListDTO> spuImageList;
    /**
     * spuSaleAttrList
     */
    @JsonProperty("spuSaleAttrList")
    private List<SpuSaleAttrListDTO> spuSaleAttrList;
    /**
     * tmId
     */
    @JsonProperty("tmId")
    private Long tmId;

    /**
     * SpuImageListDTO
     */
    @NoArgsConstructor
    @Data
    public static class SpuImageListDTO {
        /**
         * imgName
         */
        @JsonProperty("imgName")
        private String imgName;
        /**
         * imgUrl
         */
        @JsonProperty("imgUrl")
        private String imgUrl;
    }

    /**
     * SpuSaleAttrListDTO
     */
    @NoArgsConstructor
    @Data
    public static class SpuSaleAttrListDTO {
        /**
         * baseSaleAttrId
         */
        @JsonProperty("baseSaleAttrId")
        private Long baseSaleAttrId;
        /**
         * saleAttrName
         */
        @JsonProperty("saleAttrName")
        private String saleAttrName;
        /**
         * spuSaleAttrValueList
         */
        @JsonProperty("spuSaleAttrValueList")
        private List<SpuSaleAttrValueListDTO> spuSaleAttrValueList;

        /**
         * SpuSaleAttrValueListDTO
         */
        @NoArgsConstructor
        @Data
        public static class SpuSaleAttrValueListDTO {
            /**
             * baseSaleAttrId
             */
            @JsonProperty("baseSaleAttrId")
            private Long baseSaleAttrId;
            /**
             * saleAttrValueName
             */
            @JsonProperty("saleAttrValueName")
            private String saleAttrValueName;
        }
    }
}
